package org.yangspring.samples.mvc.serviceOracle;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.yangspring.samples.mvc.daoOracle.ProductDescDAO;
import org.yangspring.samples.mvc.domainOracle.ProductDesc;

import java.util.List;

import static java.lang.System.out;

/**
 * Created by whyang on 2017/06/22.
 */

@Service
public class ProductDescServiceImpl implements ProductDescService {

    private static final Logger logger = LoggerFactory.getLogger(ProductDescServiceImpl.class);

    @Autowired
    private ProductDescDAO prodDescDao;
//    public void setProdDescDao(ProductDescDAO prodDescDao){
//        this.prodDescDao = prodDescDao;
//    }

    @Transactional
    public List<ProductDesc> listProdDesc(){

        logger.warn("\nOracle ProductDescServiceImpl\n");
        return this.prodDescDao.listProdDesc();
    }

}
